package sample_schedular;

import java.util.Collections;
import java.util.LinkedList;
import java.util.List;
import java.util.Properties;
import java.util.Random;

public class RandomSampler implements Sampler {

	@Override
	public void initialize(Properties properties) {
	}

	@Override
	public List<Integer> resample(List<Integer> list, int n) {
		List<Integer> negative = new LinkedList<Integer>();
		
		for(int counter = 0; counter < list.size(); counter++) {
			negative.add(counter);
		}
		
		Collections.shuffle(negative, new Random(0));
		List<Integer> result = negative.subList(0, n);
		return result;
	}

}
